SetCSequenceKeyFrameRate
TheSetCSequenceKeyFrameRate
function adjusts the key frame rate for the current sequence.
pascal OSErr SetCSequenceKeyFrameRate (ImageSequence seqID, long keyframerate);
seqID
- Contains the unique sequence identifier that was returned by the
CompressSequenceBegin
function (described on page 3-100).keyframerate
- Specifies the maximum number of frames allowed between key frames. Key frames provide points from which a temporally compressed sequence may be decompressed. Use this parameter to control the frequency at which the compressor places key frames into the compressed sequence.
- The compressor determines the optimum placement for key frames based upon the amount of redundancy between adjacent images in the sequence. Consequently, the compressor may insert key frames more frequently than you have requested. However, the compressor will never place fewer key frames than is indicated by the setting of the
keyFrameRate
parameter. The compressor ignores this parameter if you have not requested temporal compression (that is, you have set thetemporalQuality
parameter to theCompressSequenceBegin
function to 0).- If you set this parameter to 0, the Image Compression Manager only places key frames in the compressed sequence when you call the
CompressSequenceFrame
function (described on page 3-105) and set the value of thecodecFlagForceKeyFrame
flag to 1 in theflags
parameter. If you pass in any number other than 0, it specifies the number of non-key frames between key frames. Set this parameter to 1 to specify all key frames, to 2 to specify every other frame as a key frame, to 3 to specify every third frame as a key frame, and so forth.DESCRIPTION
The key frame rate for a sequence specifies the maximum number of frames allowed between key frames. Key frames provide points from which a temporally compressed sequence may be decompressed. The new key frame rate takes effect with the next image in the sequence. See "Defining Key Frame Rates" on page 3-47 for more information about key frames.RESULT CODES
noErr 0 No error paramErr -50 Invalid parameter specified SEE ALSO
You set the default key frame rate for a sequence with thekeyFrameRate
parameter to theCompressSequenceBegin
function (described on page 3-100).